package cn.psvmc.cxzapi.mapper.store;

import cn.psvmc.cxzapi.config.mybatisplus.mapper.MyBaseMapper;
import cn.psvmc.cxzapi.model.common.SearchEntity;
import cn.psvmc.cxzapi.model.store.TAccount;
import cn.psvmc.cxzapi.model.store.TAccountRecord;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;

import java.util.Map;

/**
 * 账户提现记录表 Mapper 接口
 * @Author auto
 * @Date 2024-08-14
 */
public interface TAccountRecordMapper extends MyBaseMapper<TAccountRecord> {
    //提现记录
    IPage<Map> listRecord(Page<TAccount> iPage,@Param("entity") SearchEntity entity);

    //提现申请信息预览
    Map preRecord(@Param("entity") SearchEntity entity);

    //获取账户锁定余额和账号信息
    TAccountRecord findByAccountIdAndStoreId(@Param("accountId") Integer accountId,@Param("storeId") int storeId);

    //根据流水号查询提现记录
    TAccountRecord findByTransactionId(@Param("transactionId") String transactionId);

    void updateSatusById(@Param("ar") TAccountRecord ar);
}
